<template>
  <div class="main">
    <div class="mianbox">
      <Nav></Nav>
      <img
        src="../../static/Imgs/banner.png"
        alt="banner"
        style="cursor: pointer; height: auto; width: 100vw"
      />
      <Search></Search>
      <div class="banner">
        <div class="toptitle">
          <div class="blacktitle">首页</div>
          <div class="blacktitle">商品库</div>
          <div class="blacktitle">当季新品</div>
          <div class="blacktitle">当季热卖</div>
          <div
            style="
              font-family: PingFang SC;
              font-size: 0.18rem;
              font-weight: 900;
              color: #4479fd;
              display: flex;
              justify-content: center;
              align-items: center;
              cursor: pointer;
            "
          >
            <img
              src="../../static/Imgs/tv.png"
              alt=""
              style="margin-right: 0.08rem; cursor: pointer"
            />
            直播选品
          </div>
          <div
            style="
              font-family: PingFang SC;
              font-size: 0.18rem;
              font-weight: bold;
              color: #dccd20;
              cursor: pointer;
            "
          >
            诚信商家
          </div>
          <div
            style="
              font-family: PingFang SC;
              font-size: 0.18rem;
              font-weight: bold;
              color: #ffa60e;
              cursor: pointer;
            "
          >
            特价清仓
          </div>
        </div>
      </div>
      <div class="bannerbox">
        <div class="main">
          <div class="leftpic">
            <img
              src="../../static/bannerimg/leftpic.png"
              alt=""
              style="height: 100%; width: auto"
            />
          </div>
          <div class="Carousel">
            <div class="leftbox"></div>
            <div class="map">
              <el-carousel :interval="5000" arrow="always">
                <el-carousel-item v-for="item in 4" :key="item">
                  <h3>{{ item }}</h3>
                </el-carousel-item>
              </el-carousel>
            </div>
            <div class="rightbox">
              <div class="top">
                <img
                  src="../../static/bannerimg/king.png"
                  alt=""
                  style="margin-right: 0.1rem"
                />
                商家排行榜
              </div>
              <div class="bottom">
                <div class="item">
                  <img
                    src="../../static/bannerimg/one.png"
                    alt=""
                    style="margin-right: 0.08rem"
                  />
                  泡泡龙
                </div>
                <div class="item">
                  <img
                    src="../../static/bannerimg/two.png"
                    alt=""
                    style="margin-right: 0.08rem"
                  />
                  宝贝哼哼
                </div>
                <div class="item">
                  <img
                    src="../../static/bannerimg/three.png"
                    alt=""
                    style="margin-right: 0.08rem"
                  />
                  宝塔熊
                </div>
                <div class="item">
                  <span
                    style="
                      width: 0.2rem;
                      height: 0.2rem;
                      border-radius: 50%;
                      background: #e0dfed;
                      font-family: OPPOSans;
                      font-size: 0.12rem;
                      font-weight: bold;
                      text-align: center;
                      line-height: 0.2rem;
                      margin-right: 0.08rem;
                    "
                    >4</span
                  >
                  柴小郡女中大童
                </div>
                <div class="item">
                  <span
                    style="
                      width: 0.2rem;
                      height: 0.2rem;
                      border-radius: 50%;
                      background: #e0dfed;
                      font-family: OPPOSans;
                      font-size: 0.12rem;
                      font-weight: bold;
                      text-align: center;
                      line-height: 0.2rem;
                      margin-right: 0.08rem;
                    "
                    >5</span
                  >
                  森森
                </div>
                <div class="item">
                  <span
                    style="
                      width: 0.2rem;
                      height: 0.2rem;
                      border-radius: 50%;
                      background: #e0dfed;
                      font-family: OPPOSans;
                      font-size: 0.12rem;
                      font-weight: bold;
                      text-align: center;
                      line-height: 0.2rem;
                      margin-right: 0.08rem;
                    "
                    >6</span
                  >
                  森宝丫
                </div>
                <div class="item">
                  <span
                    style="
                      width: 0.2rem;
                      height: 0.2rem;
                      border-radius: 50%;
                      background: #e0dfed;
                      font-family: OPPOSans;
                      font-size: 0.12rem;
                      font-weight: bold;
                      text-align: center;
                      line-height: 0.2rem;
                      margin-right: 0.08rem;
                    "
                    >7</span
                  >
                  柴小郡女中大童
                </div>
                <div class="item">
                  <span
                    style="
                      width: 0.2rem;
                      height: 0.2rem;
                      border-radius: 50%;
                      background: #e0dfed;
                      font-family: OPPOSans;
                      font-size: 0.12rem;
                      font-weight: bold;
                      text-align: center;
                      line-height: 0.2rem;
                      margin-right: 0.08rem;
                    "
                    >8</span
                  >
                  柴小郡女中大童
                </div>
                <div class="item">
                  <span
                    style="
                      width: 0.2rem;
                      height: 0.2rem;
                      border-radius: 50%;
                      background: #e0dfed;
                      font-family: OPPOSans;
                      font-size: 0.12rem;
                      font-weight: bold;
                      text-align: center;
                      line-height: 0.2rem;
                      margin-right: 0.08rem;
                    "
                    >9</span
                  >
                  柴小郡女中大童
                </div>
              </div>
            </div>
          </div>
          <div class="rightpic">
            <img
              src="../../static/bannerimg/rightpic.png"
              alt=""
              style="height: 100%; width: auto"
            />
          </div>
        </div>
      </div>
      <div class="shoplistbox">
        <div class="top">
          <div class="title">
            人气<span
              style="
                color: #ec6c15;
                font-size: 0.18rem;
                display: inline-block;
                font-weight: 600;
              "
              >推荐</span
            >
            <span
              style="
                font-family: SimSun;
                font-size: 0.12rem;
                margin-top: 0.03rem;
                margin-left: 0.2rem;
                font-weight: normal;
                color: #999999;
              "
              >人气推荐广告语</span
            >
          </div>
          <div class="cards">
            <div class="carditem" v-for="item in popularitylist">
              <img :src="item.img" alt="" style="width: 100%; height: 100%" />
              <div class="titlebox">
                <div class="title">{{ item.title }}</div>
                <div class="name">{{ item.name }}</div>
              </div>
            </div>
          </div>
        </div>
        <div class="middle">
          <div class="imgboxs" v-for="item in middlelist">
            <div class="topimg">
              <img
                :src="item.img"
                alt=""
                style="width: 1.88rem; height: 1.88rem"
              />
            </div>
            <div class="Price">
              <span
                style="
                  font-size: 0.16rem;
                  color: #ffffff;
                  background-color: #fd4422;
                "
                class="leftprice"
                >{{ item.Price }}</span
              ><span
                style="font-size: 0.12rem; color: #999999; margin-left: 0.2rem"
                >{{ item.name }}</span
              >
            </div>
            <div class="bottomtitle">{{ item.title }}</div>
          </div>
        </div>
        <div class="bottom">
          <img
            src="../../static/popularityimgs/bottomimg.png"
            alt=""
            style="width: 12rem"
          />
        </div>
      </div>
      <div class="sells">
        <div class="title">
          实力<span
            style="
              color: #ec6c15;
              font-size: 0.18rem;
              display: inline-block;
              font-weight: 600;
            "
            >爆卖</span
          >
          <span
            style="
              font-family: SimSun;
              font-size: 0.12rem;
              margin-top: 0.03rem;
              margin-left: 0.2rem;
              font-weight: normal;
              color: #999999;
            "
            >诚信店铺 品质精选</span
          >
          <span
            style="
              float: right;
              font-family: SimSun;
              font-size: 0.12rem;
              color: #999999;
              flex: 1;
              text-align: right;
              cursor: pointer;
            "
            >更多诚信商家货源>></span
          >
        </div>
        <div class="card">
          <div class="leftadvertising">
            <img
              src="../../static/popularityimgs/guanggao.png"
              alt=""
              style="width: 100%; height: 100%"
            />
          </div>
          <div class="carditem">
            <div v-for="item in 10">
              <Card></Card>
            </div>
          </div>
        </div>
      </div>
      <div class="sellsbottom">
        <div class="title">
          实力<span
            style="
              color: #ec6c15;
              font-size: 0.18rem;
              display: inline-block;
              font-weight: 600;
            "
            >爆卖</span
          >
          <span
            style="
              font-family: SimSun;
              font-size: 0.12rem;
              margin-top: 0.03rem;
              margin-left: 0.2rem;
              font-weight: normal;
              color: #999999;
            "
            >诚信店铺 品质精选</span
          >
          <span
            style="
              float: right;
              font-family: SimSun;
              font-size: 0.12rem;
              color: #999999;
              flex: 1;
              text-align: right;
              cursor: pointer;
            "
            >更多诚信商家货源>></span
          >
        </div>
        <div class="card">
          <!-- <div class="leftadvertising">
            <img
              src="../../static/popularityimgs/guanggao.png"
              alt=""
              style="width: 100%; height:100%;"
            />
          </div> -->
          <div class="carditem">
            <div v-for="item in 4">
              <Card
                :width="'2.05'"
                height="2.08"
                :bottom="'0.4'"
                :boxheight="'3.62'"
              ></Card>
            </div>
            <div class="guanggao">
              <img
                src="../../static/popularityimgs/rightguanggao.png"
                alt=""
                style="width: 2.18rem; height: 3.62rem; margin-left: 0.2rem"
              />
            </div>
          </div>
        </div>
      </div>
      <div class="endbox" v-for="item in 3">
        <img
          src="../../static/popularityimgs/endpic.png"
          alt=""
          style="width: 100%"
        />
        <div class="carditem">
          <Card
            v-for="item in 5"
            :width="'2.05'"
            height="2.08"
            :bottom="'0.4'"
            :boxheight="'3.62'"
          ></Card>
        </div>
      </div>
      <div class="fotter">
        <Footer></Footer>
      </div>
    </div>
  </div>
</template>

<script>
import Nav from '../../components/Nav/Nav.vue'
import Search from '../../components/Search/Search.vue'
import Card from './components/Card.vue'
import Footer from '../../components/bottom/index.vue'
export default {
  components: {
    Nav,
    Search,
    Card,
    Footer
  },

  data () {
    return {
      popularitylist: [
        {
          img: require('../../static/popularityimgs/one.png'),
          title: '新欧巴服饰',
          name: '秋季新款'
        },
        {
          img: require('../../static/popularityimgs/two.png'),
          title: '小豆町',
          name: '秋款上新'
        },
        {
          img: require('../../static/popularityimgs/three.png'),
          title: '贝特英服饰',
          name: '秋季新款'
        },
        {
          img: require('../../static/popularityimgs/four.png'),
          title: '瑶含之星',
          name: '秋季新款'
        },
        {
          img: require('../../static/popularityimgs/five.png'),
          title: '三和童装',
          name: '秋季新款'
        },
        {
          img: require('../../static/popularityimgs/six.png'),
          title: '南波兔',
          name: '秋季新款'
        }
      ],
      middlelist: [
        {
          img: require('../../static/popularityimgs/middleone.png'),
          title: '女童小香风外套秋装新款...',
          name: '分销：136',
          Price: '￥59.00'
        },
        {
          img: require('../../static/popularityimgs/middletwo.png'),
          title: '牛仔背带裙',
          name: '分销：52',
          Price: '￥59.00'
        },
        {
          img: require('../../static/popularityimgs/middlethree.png'),
          title: '现货',
          name: '分销：78',
          Price: '￥59.00'
        },
        {
          img: require('../../static/popularityimgs/middlefour.png'),
          title: '男童卫衣春秋款炸街2023新款',
          name: '分销：277',
          Price: '￥59.00'
        },
        {
          img: require('../../static/popularityimgs/middlefive.png'),
          title: '男童秋装外套2023新款男童外',
          name: '分销：141',
          Price: '￥59.00'
        },
        {
          img: require('../../static/popularityimgs/middlesix.png'),
          title: '男童秋装外套2023新款男童外',
          name: '分销：146',
          Price: '￥59.00'
        }
      ]
    }
  },
  created () {},
  methods: {}
}
</script>

<style scoped lang="scss">
::v-deep .el-carousel__arrow--left {
  border-radius: 0 0.2rem 0.2rem 0 !important;
  left: 0;
}
::v-deep .el-carousel__arrow--right {
  border-radius: 0.2rem 0 0 0.2rem !important;
  right: 0;
}
.main {
  width: 100%;
  // height: 100%;
  background-color: #f5f7f9;
  .mianbox {
    margin: 0 auto;
    width: 12rem;
    height: 100%;

    display: flex;
    flex-direction: column;
    align-items: center;
    .banner {
      width: 100vw;
      background-color: #fff;
      .toptitle {
        margin: 0 auto;
        margin-top: 0.1rem;
        width: 12rem;
        display: flex;
        justify-content: space-around;
        align-items: center;

        .blacktitle {
          font-family: PingFang SC;
          font-size: 0.16rem;
          font-weight: bold;
          cursor: pointer;
          padding: 0.1rem 0.3rem;
        }
      }
    }
    .bannerbox {
      width: 100vw;
      background: linear-gradient(270deg, #ffcbcd 40%, #ffd3d5 63%);
      height: 3.86rem;
      .main {
        width: 14.4rem;
        height: 100%;
        margin: 0 auto;
        display: flex;
        // background-color: green;
        .leftpic {
          width: 1.2rem;
          height: 3.86rem;
        }
        .map {
          flex: 1;
        }
        .Carousel {
          width: 12rem;
          height: 100%;
          background: linear-gradient(270deg, #ffcbcd 40%, #ffd3d5 63%);
          display: flex;
          justify-content: center;
          align-items: end;
          .leftbox {
            width: 1.6rem;
            height: 100%;
            border: 0.01rem solid rgba(0, 0, 0, 0);
            background: #ffffff;
          }
          .rightbox {
            width: 1.7rem;
            height: 3.3rem;
            background-color: #fff;
            border: 0.01rem solid rgba(0, 0, 0, 0);
            border-radius: 0.2rem 0.2rem 0 0;
            padding: 0.17rem 0.085rem 0.2716rem 0.105rem;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            .top {
              display: flex;
              justify-content: center;
              align-items: center;
              font-family: PingFang SC;
              font-size: 0.12rem;
              font-weight: bold;
              color: #fdbb4a;
              margin-bottom: 0.18rem;
            }
            .bottom {
              flex: 1;
              background: #f5f7f9;
              width: 100%;
              height: 100%;
              .item {
                font-family: PingFang SC;
                font-size: 0.12rem;
                font-weight: 500;
                display: flex;
                align-items: center;
                // justify-content: center;
                width: 1.613rem;
                height: 0.1963rem;
                padding: 0.0628rem 0 0.069rem 0.087rem;
                text-align: center;
                font-weight: 500;
                color: #000000;
              }
            }
          }
        }
      }
    }
    .shoplistbox {
      width: 12rem;
      height: 100%;
      margin-top: 0.2rem;
      margin-bottom: 0.2rem;

      .top {
        margin-bottom: 0.2rem;
        background-color: #fff;
        padding: 0.22rem 0.1rem 0.1rem 0.1rem;
        .title {
          display: flex;
          // justify-content: center;
          align-items: center;
          font-family: HYk1gj-regular;
          font-size: 0.18rem;
          font-weight: 600;
          color: #000000;
        }
        .cards {
          margin-top: 0.22rem;
          margin-bottom: 0.2rem;
          width: 100%;
          display: flex;
          justify-content: space-between;
          align-items: center;
          .carditem {
            margin-left: 0.1rem;
            position: relative;
            margin-left: 0.08rem;
            width: 1.9rem;
            height: 2.77rem;
            background-color: pink;
            .titlebox {
              display: flex;
              flex-direction: column;
              justify-content: center;
              align-items: center;
              position: absolute;
              bottom: 0.1rem;
              left: 0.1rem;
              width: 1.72rem;
              height: 0.55rem;
              opacity: 0.7;
              background: #ffffff;
              .title {
                font-family: PingFang SC;
                font-size: 0.16rem;
                font-weight: bold;
                color: #000000;
              }
              .name {
                font-family: OPPOSans;
                font-size: 0.12rem;
                font-weight: normal;
                line-height: normal;
                text-align: center;
                letter-spacing: 0em;
                opacity: 0.7;

                /* 正文灰 */
                color: #666666;
              }
            }
          }
        }
      }
      .middle {
        height: 2.92rem;
        opacity: 1;
        padding: 0.2rem 0.12rem 0.2rem 0.1rem;
        background: #ffffff;
        box-sizing: border-box;
        border: 0.01rem solid rgba(0, 0, 0, 0);
        display: flex;
        justify-content: center;
        align-items: center;
        margin-bottom: 0.2rem;
        .imgboxs {
          display: flex;
          flex-direction: column;
          justify-content: center;
          align-items: center;
          width: 1.88rem;
          height: 2.62rem;
          background: #f5f7f9;
          box-sizing: border-box;
          border: 0.01rem solid rgba(0, 0, 0, 0);
          margin-left: 0.1rem;
          .Price {
            display: flex;
            // justify-content: space-around;
            align-items: center;
            width: 1.46rem;
            height: 0.32rem;
            border: 0.01rem solid #ff6721;
            .leftprice {
              position: relative;
            }
            .leftprice::before {
              content: "";
              position: absolute;
              width: 0;
              height: 0;
              border: 0.148rem solid;
              border-color: transparent #fd4422 transparent transparent;
              top: -0.16rem;
              left: 0.401rem;
              width: 0.03rem;
              height: 0.02rem;
              transform: rotate(45deg);
            }
          }
          .bottomtitle {
            font-family: OPPOSans;
            font-size: 0.12rem;
            font-weight: normal;
            line-height: normal;
            text-align: center;
            letter-spacing: 0em;
            margin-top: 0.1rem;
            /* 标题正文黑 */
            color: #000000;
          }
        }
      }
      .bottom {
        height: 1.5rem;
      }
    }
    .sells {
      height: 7.6rem;
      background-color: #fff;
      width: 100%;
      margin-bottom: 0.2rem;
      .title {
        display: flex;

        align-items: center;
        width: calc(100%-0.42rem);
        height: 0.19rem;
        // background-color: green;
        padding: 0.21rem 0.26rem 0.21rem 0.16rem;
        font-family: HYk1gj-regular;
        font-size: 0.18rem;
        font-weight: 600;
      }
      .card {
        width: calc(100%-0.24rem);

        // background-color: pink;
        display: flex;
        padding: 0 0.14rem 0.3rem 0.1rem;

        .leftadvertising {
          width: 1.83rem;
          height: 6.7rem;
          background-color: green;
        }
        .carditem {
          display: flex;
          justify-content: space-between;
          align-items: center;
          flex-wrap: wrap;
          width: 10.91rem;
          margin-left: 0.1rem;
        }
      }
    }
    .sellsbottom {
      height: 4.45rem;
      background-color: #fff;
      width: 100%;
      margin-bottom: 0.2rem;
      .title {
        display: flex;

        align-items: center;
        width: calc(100%-0.42rem);
        height: 0.19rem;
        // background-color: green;
        padding: 0.21rem 0.26rem 0.21rem 0.16rem;
        font-family: HYk1gj-regular;
        font-size: 0.18rem;
        font-weight: 600;
      }
      .card {
        width: calc(100%-0.24rem);

        // background-color: pink;
        display: flex;
        padding: 0 0.14rem 0.3rem 0.1rem;

        .carditem {
          display: flex;
          justify-content: space-evenly;
          // align-items: center;
          flex-wrap: wrap;
          width: 10.91rem;
          margin-left: 0.1rem;
          .guanggao {
            width: 1.74rem;
            height: 3.2rem;
          }
        }
      }
    }
    .endbox {
      width: 100%;
      height: 5.48rem;
      background-color: white;
      margin-bottom: 0.2rem;
      .carditem {
        margin-top: -0.1rem;
        display: flex;
        justify-content: space-evenly;
        // align-items: center;
        flex-wrap: nowrap;
        // width: 10.91rem;
        margin-left: 0.1rem;
      }
    }
    .fotter {
      width: 100vw;
      background-color: #fff;
    }
  }
}
</style>
